<template>
	<view class="container">
		<view class="section">
			<view class="title">申请时间</view>
			<view class="text">{{created_time}}</view>
		</view>
		<view class="section">
			<view class="title">姓名</view>
			<view class="text">{{name}}</view>
		</view>
		<view class="section">
			<view class="title">安装地址</view>
			<view class="text">{{address}}</view>
		</view>
		<view class="section">
			<view class="title">加入时间</view>
			<view class="text">{{join_time}}</view>
		</view>
		<view class="section">
			<view class="title">手机号码</view>
			<view class="text">{{phone}}</view>
		</view>
		<view class="section">
			<view class="title">状态</view>
			<view class="text" v-if="status == 0">审核中</view>
			<view class="text" v-if="status == 1">已通过</view>
			<view class="text" v-if="status == 2">未通过</view>
			<view class="text" v-if="status == 3">已过期</view>
		</view>
		<view class="section" v-if="reason != ''">
			<view class="title">拒绝理由</view>
			<view class="text">{{reason}}</view>
		</view>
		<view class="section" v-if="status==1">
			<view class="title">通过时间</view>
			<view class="text">{{audi_time}}</view>
		</view>
		<view class="section" v-if="status==1">
			<view class="title">使用开始时间</view>
			<view class="text">{{start_time}}</view>
		</view>
		<view class="section" v-if="status==1">
			<view class="title">使用结束时间</view>
			<view class="text">{{end_time}}</view>
		</view>
	</view>
</template>

<script>
	import {toLogin} from "@/libs/login.js";
	import {mapGetters} from "vuex";
	import {getProductDetail} from "@/api/product.js";
	import parser from "@/components/jyf-parser/jyf-parser";
	
	// #ifdef MP
	import authorize from "@/components/Authorize";
	// #endif
	export default {
		components: {
			parser,
			// #ifdef MP
			authorize,
			// #endif
		},
		data() {
			return {
				created_time:'',
				name:'',
				address:'',
				join_time:'',
				phone:'',
				status:'',
				reason:'',
				audi_time:''
			}
		},
		computed: mapGetters(["isLogin"]),
		watch: {
			isLogin: {
				handler: function(newV, oldV) {
					if (newV == true) {
						console.info(111)
						// this.getCouponList();
						// this.getCartCount();
						// this.downloadFilePromotionCode();
					}
				},
				deep: true,
			}
		},
		onLoad(options) {
			this.created_time = options.created_time;
			this.name = options.name;
			this.address = options.address;
			this.phone = options.phone;
			this.join_time = options.join_time;
			this.audi_time = options.audi_time;
			this.status = options.status;
		},
		methods: {
			
		}
	}
</script>

<style lang="scss" scope>
	.container {
		background-color: #F5F5F5;
		padding-bottom: 0;
		padding-bottom: constant(safe-area-inset-bottom);  
		padding-bottom: env(safe-area-inset-bottom); 
	}
	.section{
		display: flex;
		flex-direction: row;
		background-color: white;
		padding: 30rpx;
		border-bottom: 1rpx solid #f1f1f1;
		.title{
			width: 150rpx;
			font-size: 28rpx;
			color: black;
		}
		.text{
			font-size: 28rpx;
			color: black;
		}
	}
</style>
